<h1 mat-dialog-title>{{ 'Delete User' | translate }}</h1>
<div mat-dialog-content>
  <p class="message" [innerHtml]="deleteMessage | translate: { user: user.username }"></p>

  @if (isLastGroupMember) {
    <ix-checkbox
      class="delete-checkbox"
      ixTestOverride="delete-primary-group"
      [formControl]="deleteGroupCheckbox"
      [label]="'Delete user primary group `{name}`' | translate: { name: user.group.bsdgrp_group }"
    ></ix-checkbox>
  }
</div>
<ix-form-actions mat-dialog-actions class="form-actions">
  <button mat-button ixTest="cancel" [matDialogClose]="false">{{ 'Cancel' | translate }}</button>
  <button
    *ixRequiresRoles="requiredRoles"
    mat-button
    color="warn"
    ixTest="delete"
    (click)="onDelete()"
  >
    {{ 'Delete' | translate }}
  </button>
</ix-form-actions>
